package service;

import android.app.Service;
import android.content.Intent;
import android.os.Binder;
import android.os.IBinder;
import android.support.annotation.Nullable;
import android.util.Log;

public class Myservice extends Service {

    public static final String TAG = "Myservice";

    @Nullable
    @Override
    public IBinder onBind(Intent intent) {
        Log.d(TAG, "-----onBind-----");
        return null;
    }

    @Override
    public boolean onUnbind(Intent intent) {
        Log.d(TAG, "-----onUnbind-----");
        return super.onUnbind(intent);
    }

    @Override
    public void onCreate() {
        Log.d(TAG, "-----onCreate-----");
        super.onCreate();
    }

    @Override
    public int onStartCommand(Intent intent, int flags, int startId) {
        Log.d(TAG, "-----onStartCommand-----");
        return super.onStartCommand(intent, flags, startId);
    }

    @Override
    public void onDestroy() {
        Log.d(TAG, "-----onDestroy-----");
        super.onDestroy();
    }
    public class Mybinder extends Binder{
        public void func(){
            System.out.println("hello");
        }
    }
}
